import time

from Uniut1.Tools import Tools
import unittest
from BeautifulReport import BeautifulReport
if __name__ == '__main__':
    Tools().log()
    sleep_time = time.strftime("%Y%m%d-%H%M%S")
    suite=unittest.defaultTestLoader.discover(start_dir="./",pattern="TestCase.py")
    runner=BeautifulReport(suite).report(description="这是报告",filename=f"{sleep_time}")
    Tools().mail([f"{sleep_time}.log",f"{sleep_time}.html"])